package com.homework.test2;

public class Demo5 {
    public static void main(String[] args) {
        int[] arr = {95, 92, 75, 56, 98, 71, 80, 58, 91, 91};
        int max = 0;
        int min = arr[0];
        for (int i : arr) {
            if (max < i) {
                max = i;
            }
            if (min > i) {
                min = i;
            }
        }
        System.out.println("max = " + max);
        System.out.println("min = " + min);
    }
}
